/**
 * @Author: likang xie
 * @Date: 2019-11-06 17:11:52
 * @Usage 任务模块接口列表
 */

import request from "@/utils/request";

let extra = {
  showLoading: false,
};

// 任务列表
export let listTask = (params) => request.get("/doc/tasks", params, extra);

// 任务详情
export let detailTask = (params) => request.get("/doc/myTask/detail", params);

// 关注任务
export let focus = (params) => request.get("/doc/user/addFocus", params);

// 取消关注任务
export let cancelFocus = (params) =>
  request.post("/doc/my/cancel_task_collection", params);

// 获取任务修改记录
export let listUpdateInfo = (params) =>
  request.get("/doc/task/modifyList", params, extra);

// 获取任务交付稿件列表
export let listDelivery = (params) =>
  request.get("/doc/task/deliveryList", params, extra);

// 我要投标
export let contribute = (params) =>
  request.post("/doc/work/createWinBid", params);

// 交付稿件
export let deliver = (params) =>
  request.post("/doc/work/createDelivery", params);

// 创建任务
export let createTask = (params) =>
  request.post("/doc/createTask2", params);

  
// 发送邮件
export let sendFileToEmail = (params) =>
request.post("/doc/sendFileToEmail", params);


// 过滤任务
export let testContent = (params) =>
request.post("/doc/task/test_content", params);


// 省市区
export let getDistrict = (params) =>
request.get("/doc/getDistrict", params);


// 省市区
export let getCateTree = (params) =>
request.get("/doc/getCateTree", params);



// http://120.27.199.64:8518/task/getFileName

// 上传
export let getFileName = (params) =>
request.get("/doc/getFileName", params);


export let userSkills = (params) =>
request.post("/doc/skill/userSkills ", params);


// 稿件中标
export let bid = (params) => request.get("/doc/work/winBid", params);

// 获取增值服务列表
export let listUpService = (params) =>
  request.get("/doc/myTask/gettaskService", params);

// 创建修改记录/回复
export let createUpdate = (params) => request.post("/doc/task/bc", params);

// 招标任务保存付款方式（雇主）
export let postPayType = (params) =>
  request.post("/doc/myTask/postPayType", params);

// 招标任务确认付款方式（威课）
export let dealPayType = (params) =>
  request.get("/doc/myTask/dealPayType", params);

// 验收
export let checkTask = (params) =>
  request.get("/doc/work/deliveryAgree", params);

// 评价
export let taskRate = (params) => request.post("/doc/work/evaluate", params);
